package com.mock.water.config.shiro;

import lombok.extern.slf4j.Slf4j;
import org.apache.shiro.session.Session;
import org.apache.shiro.session.SessionListener;
import org.springframework.stereotype.Component;

/**
 * @Author ifredomvip@gmail.com
 * @Date 2023/3/27 23:56
 */
@Slf4j
@Component
public class ShiroSessionListener implements SessionListener {
    @Override
    public void onStart(Session session) {
        log.info("【shiro的Session监听器】---onStart....uuid="+session.getId().toString());
    }

    @Override
    public void onStop(Session session) {
        log.info("【shiro的Session监听器】---onStop....uuid="+session.getId().toString());
    }

    @Override
    public void onExpiration(Session session) {
        log.info("【shiro的Session监听器】---onExpiration....uuid="+session.getId().toString());
    }
}
